<template>
	<KycItem
		titleT="settings.kyc.Email"
		:type="SettingsShowEnum.email"
		:status="!!profileStore.userInfo?.emailVerify"
		icon="email">
		<div v-if="profileStore.userInfo?.emailVerify" class="py-[14px]">
			{{ profileStore.email }}
		</div>
		<BaseButton
			v-else
			class="h-10"
			:block="false"
			type="primary"
			textT="settings.kyc.Verify"
			@click="onClick" />
	</KycItem>
</template>

<script setup lang="ts">
import { BaseButton } from '@/components/base'
import { useProfileStore } from '@/store'
import { SettingsShowEnum } from '@/types'
import { KycItem } from '../components'

const emits = defineEmits(['clickEffect'])
const profileStore = useProfileStore()

const onClick = () => {
	emits('clickEffect')
	profileStore.show.email = true
}
</script>
